Network devices such as network interface cards (NICs), routers, switches, hubs, and the like generally communicate across a network by transmitting and receiving packets. Packets are units of data transmitted over a network. Network communications are often broken into packets because network devices often can only transmit small units of data, and therefore, transmitting a large amount of data over a network may be facilitated by dividing the data into related packets to be transmitted.
When a network device sends a packet, the packet will be stored in the memory of the host until it has successfully been sent out to the wire (i.e., over the network) or received by the receiving remote node. The network device generates an interrupt to notify the processor of the network device that the packet has been delivered to the receiving remote host. The interrupt handler on the host releases the memory buffer for that packet. When a network device receives a packet, the packet will be stored in the memory until the receiving node delivers this packet to the destination receiving node. Then, the network device may generate an interrupt to notify the receiving interrupt handler to process this packet. The receiving process may release the packet memory buffer after processing that packet for a new incoming packet.
Many network devices have a limited sending or receiving ring (also called a “queue”) in which to temporarily store data associated with packets. For example sending and receiving rings can be multi-cell arrays that include memory references to different packets stored in the memory. If the limited send or receiving ring happens to be full, then the network device will not be able to send or receive a subsequent packet. The subsequent packets will be dropped (i.e., will fail to be sent or received by the network device), thereby impacting the network performance. In this case, these packets need to be retransmitted so that they can be sent or received by the network device. The transmit or receive completion interrupts can cause network  communications to slow down because they induce significant context switch overhead between executing transmitting or receiving processes and processing interrupts. Specifically, when a network device is executing transmit or receive completion interrupts, the transmitting and receiving processes temporarily stop for the processor to process these interrupts. This can cause significant processor utilization, and could temporarily prevent packets from being sent or received by the network device, thereby slowing down the network throughput.
Therefore, what is needed are systems and methods for aggregating transmit or receive completion interrupts for multiple packets, thereby reducing the amount of time the communications are interrupted, increasing network throughput, reducing the processor utilization of the node, and utilizing cache locality by aggregating a group or “chunk” of packets to be released at once from the host.